﻿
Public Class function_call3
    Inherits function_call2

    Public Const start2 As Char = character.equalSign

    Protected Friend Shared Shadows Function _isMeaningfulMark(ByVal c As Char) As Boolean
        Return isstart2(c)
    End Function

    Private Sub New(ByVal name As String, ByVal ps As parameters_list3)
        MyBase.New(name, ps)
    End Sub

    Private Shared Function isstart2(ByVal c As Char) As Boolean
        Return c = start2
    End Function

    Private Shared Function parseImpl(ByVal input As String, ByRef index As Int64, _
                                      ByRef output As function_call3) As Boolean
        Dim hasstart2 As Boolean = False
        Dim startindex As Int64 = index
        hasstart2 = token(input, index, Nothing, AddressOf isstart2, AddressOf [false])
        Dim ps As parameters_list3 = Nothing
        ps = New parameters_list3()
        Dim name As String = Nothing
        If ps.parse(input, index, True) AndAlso _
           operator_name_defination.parse(input, index, name) AndAlso _
           ps.parse(input, index, False) Then
            output = New function_call3(name, ps)
            If hasstart2 Then
                raiseError(errorHandle.errorType.user, "suggest to remove ", start2, " for function_call3, ", _
                           displaySource(input, startindex))
            End If
            Return True
        End If

        Return False
    End Function

    Public Shared Shadows Function parse(ByVal input As String, ByRef index As Int64, _
                                         ByRef output As function_call3) As Boolean
        Return parsebase(input, index, output, AddressOf parseImpl)
    End Function
End Class
